/**
 * 
 */
package org.xlab.familystore.domain;

import java.io.Serializable;
import java.util.Date;

import com.j256.ormlite.field.DatabaseField;
import com.j256.ormlite.table.DatabaseTable;

/**
 * @author makubex
 * 
 */
@DatabaseTable(tableName="INVENTORY_")
public class Inventory implements Serializable {
	/**
	 * @serialField
	 */
	private static final long serialVersionUID = -7078514772791170904L;
	@DatabaseField(generatedId = true)
	private int id;
	@DatabaseField
	private Date lastUpdatedTime;
	@DatabaseField(foreign = true, canBeNull = false)
	private Commodity commodity;
	@DatabaseField(defaultValue="0")
	private int availableQty;
	@DatabaseField(defaultValue="0")
	private int purchaseQty;
	
	
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
	public Date getLastUpdatedTime() {
		return lastUpdatedTime;
	}
	public void setLastUpdatedTime(Date lastUpdatedTime) {
		this.lastUpdatedTime = lastUpdatedTime;
	}
	public Commodity getCommodity() {
		return commodity;
	}
	public void setCommodity(Commodity commodity) {
		this.commodity = commodity;
	}
	public int getAvailableQty() {
		return availableQty;
	}
	public void setAvailableQty(int availableQty) {
		this.availableQty = availableQty;
	}
	public int getPurchaseQty() {
		return purchaseQty;
	}
	public void setPurchaseQty(int purchaseQty) {
		this.purchaseQty = purchaseQty;
	}
}
